package com.chinasofti.IO;

import java.io.File;

public class Demo03 {
    public static void main(String[] args) {
        File file = new File("java0418\\java.txt");
        System.out.println(file.isDirectory());
        System.out.println(file.isFile());
        System.out.println(file.exists());
        System.out.println(file.getAbsoluteFile());
        System.out.println(file.getPath());
        System.out.println(file.getName());
        System.out.println("*************************");
        File file1 = new File("java0418\\changxin");
        File[] files = file1.listFiles();
        for (File file2 : files){
            System.out.println(file2);
            System.out.println(file2.getName());
            if (file.isFile()){
                System.out.println(file.getName());
            }
        }
    }
}
